<!DOCTYPE html>
<html lang="en">
<head>
    <title>Calendar - Selection</title>
    <meta charset="utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <meta name="description" content="" />
    <meta name="keywords" content="" />
    <meta name="author" content="ComponentOne" />
    <link href="../../themes/rocket/jquery-wijmo.css" rel="stylesheet" type="text/css" />
    <script src="../../external/jquery-1.8.0.min.js" type="text/javascript"></script>
    <script src="../../external/jquery-ui-1.8.23.custom.min.js" type="text/javascript"></script>
    <link href="../../themes/wijmo/jquery.wijmo.wijcalendar.css" rel="stylesheet" type="text/css" />
    <script src="../../external/globalize.min.js" type="text/javascript"></script>
    <script src="../../wijmo/jquery.wijmo.wijpopup.js" type="text/javascript"></script>
    <script src="../../wijmo/jquery.wijmo.wijcalendar.js" type="text/javascript"></script>
    <script type="text/javascript">
        $(function () {
            $("#calendar1").wijcalendar({
                showWeekDays: true,
                showWeekNumbers: true
            });

            $.each(["day", "days", "weekDay", "weekNumber", "month"], function (i, name) {
                $("#" + name).attr("checked", !!$("#calendar1").wijcalendar("option", "selectionMode")[name]);
            });

            $("input[type=checkbox]").change(function () {
                var chk = $(this);
                var selMode = $("#calendar1").wijcalendar("option", "selectionMode");
                selMode[chk.val()] = chk[0].checked;
                $("#calendar1").wijcalendar("option", "selectionMode", selMode);
            });
        });
	
    </script>
</head>
<body class="demo-single">
    <div class="container">
        <div class="header">
            <h2>
                Selection</h2>
        </div>
        <div class="main demo">
            <!-- Begin demo markup -->
            <div id="calendar1">
            </div>
            <!-- End demo markup -->
            <div class="demo-options">
                <!-- Begin options markup -->
                <div class="option-row">
                    <input type="checkbox" name="selectionmode" id="day" value="day" />Day
                    <input type="checkbox" name="selectionmode" id="days" value="days" />Days
                    <input type="checkbox" name="selectionmode" id="weekDay" value="weekDay" />Week
                    Day
                    <input type="checkbox" name="selectionmode" id="weekNumber" value="weekNumber" />Week
                    Number
                    <input type="checkbox" name="selectionmode" id="month" value="month" />Month
                </div>
                <!-- End options markup -->
            </div>
        </div>
        <div class="footer demo-description">
            <p>
                The wijcalendar widget can have its dates selected in a number of ways. This sample
                will show you how the day, days, weekday, week number, and month settings work.
                To see a specific selection mode, just select the check box.
            </p>
        </div>
    </div>
</body>
</html>
